//
//  ConsModel.m
//  11214
//
//  Created by student on 16/3/8.
//  Copyright © 2016年 niit. All rights reserved.
//

#import "ConsModel.h"

@implementation ConsModel

-(instancetype)initWithDict:(NSDictionary *)dict{
    if (self=[super init]) {
        [self setValuesForKeysWithDictionary:dict];
    }
    return self;
}


+(instancetype)consWithDict:(NSDictionary *)dict{

    return [[self alloc]initWithDict:dict];
}

+(NSArray *)consArr{
    NSString *path=[[NSBundle mainBundle]pathForResource:@"constellation" ofType:@"plist"];
    NSArray *arr=[NSArray arrayWithContentsOfFile:path];
    NSMutableArray *mArr=[NSMutableArray array];
    for (NSDictionary *dict in arr) {
        ConsModel *c=[ConsModel consWithDict:dict];
        [mArr addObject:c];
  }
    return mArr;
}
@end
